package com.bqtt.tumor.demo.entity;

import java.util.HashMap;
import java.util.Map;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Transient;

import com.bqtt.tumor.demo.common.utility.InlineTools;

@Entity
@Table(name="feature_def") 
public class Feature  implements IDBEntity{

	
	@Id 
    @Column(name="feature_id")    
    @GeneratedValue(strategy=GenerationType.IDENTITY) 
	private Integer feature_id;
	
	
	@Column(name="category")   
	private int category;
	
	
	@Column(name="feature_describe_note",length=500)   
	private String feature_describe_note;


	@Transient
	private String displayName;
	
	
	@Transient
	private String checked;
	
	
	
	public String getChecked() {
		return checked;
	}

	public void setChecked(String checked) {
		this.checked = checked;
	}

	public String getDisplayName() {
		return displayName;
	}

	public void setDisplayName(String displayName) {
		this.displayName = displayName;
	}
	
	
	
	@Override
	public Map<String, Object> getSQLValidAttributes() {
		// TODO Auto-generated method stub
		Map<String,Object> result = new HashMap<String,Object>();
		
 
		result.put("category", category);

		
		if(!InlineTools.isEmpty(feature_describe_note))
		{
			result.put("feature_describe_note", feature_describe_note);
		}

		return result;
	}


	@Override
	public void fillStringField() {
		// TODO Auto-generated method stub
		
	}


	@Override
	public void fillDBfields() {
		// TODO Auto-generated method stub
		
	}


	public Integer getFeature_id() {
		return feature_id;
	}


	public void setFeature_id(Integer feature_id) {
		this.feature_id = feature_id;
	}



	public int getCategory() {
		return category;
	}


	public void setCategory(int category) {
		this.category = category;
	}


	public String getFeature_describe_note() {
		return feature_describe_note;
	}


	public void setFeature_describe_note(String feature_describe_note) {
		this.feature_describe_note = feature_describe_note;
	}

	public Feature() {
		super();
		displayName="none";
		checked=InlineTools.nocheckedStyle;
		// TODO Auto-generated constructor stub
	}
	
}
